package 创建者模式.原型模式.浅克隆.Demo;

public class Citation implements Cloneable{
    //三好学生上的姓名
    private String name;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    @Override
    public Citation clone() throws CloneNotSupportedException {
        return (Citation) super.clone();//因为强转所以为同一个对象
    }

    public void show(){
        System.out.println(name+"同学获得三好学生特发奖状");
    }
}
